package com.jack.blog.dao;

import com.jack.blog.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserMapper {

    List<User> queryUsers();

    User queryUserById(@Param("id") int id);

    User queryUserByUsername(@Param("username") String username);

    void insertUser(@Param("username")String username,@Param("password")String password,@Param("avatarUrl")String avatarUrl,@Param("nickName")String nickName,@Param("introduction")String introduction);

    void updateUserInfo(@Param("id")int id, @Param("password") String password, @Param("avatarUrl") String avatarUrl, @Param("nickName")String nickName, @Param("introduction")String introduction);

    void deleteUser(@Param("id")int id);

}
